package edu.biwu.test;

import edu.biwu.sms.MiddleStudent;
import edu.biwu.sms.PrimaryStduent;
import edu.biwu.sms.StudentManagementSystem02;
import org.junit.Test;

import java.time.LocalDate;

public class smsTest03 {

    @Test
    public  void  getPropertyValue() throws Exception {
        PrimaryStduent ps = new PrimaryStduent("20241316", "小新", 77, 81,
                LocalDate.parse("2013-10-12"), "233434@qq.com");
        StudentManagementSystem02 sms = new StudentManagementSystem02();
        System.out.println(sms.getPropertyValue(ps, "name"));
        sms.setPropertyValue(ps,"name","hh");
        System.out.println(sms.getPropertyValue(ps, "name"));
    }
    @Test
    public  void  getPropertyValue01() throws Exception {
        MiddleStudent ms = new MiddleStudent("20241316","大新",97,81,LocalDate.parse("2023-10-15"),"27722495973@qq.com",98,23);
        StudentManagementSystem02 sms = new StudentManagementSystem02();
        System.out.println(sms.getPropertyValue(ms, "stuId"));
        sms.setPropertyValue(ms,"name","syh");
        System.out.println(sms.getPropertyValue(ms, "name"));
    }
}
